#ifndef CHAINGRAPHALGORITHM_H_
#define CHAINGRAPHALGORITHM_H_

#include <vector>

#include <boost/shared_ptr.hpp>

#include "IGraphAlgorithm.h"

namespace native_orbitor
{

class ChainGraphAlgorithm : public IGraphAlgorithm
{
public:
	typedef boost::shared_ptr< IGraphAlgorithm > AlgPtr;

public:
	ChainGraphAlgorithm();
	ChainGraphAlgorithm( AlgPtr * const subalgorithms, int length );

public:
	void pushbackSubalgorithm( const AlgPtr & subalgorithm );
	void pushbackAllSubalgorithms( const AlgPtr * subalgorithms, size_t length );

public:
	virtual bool isApplicable2graph( GRAPH_SUPPORT_NS::Graph * abstractGraphPtr );
	virtual void runOnGraph( GRAPH_SUPPORT_NS::Graph * abstractGraphPtr );

private:
	std::vector< AlgPtr > subalgorithms;
};

}

#endif /* CHAINGRAPHALGORITHM_H_ */
